package com.eastfair.security.constant;

import lombok.Data;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.cloud.context.config.annotation.RefreshScope;
import org.springframework.stereotype.Component;

import java.io.Serializable;
import java.util.List;

/**
 * 系统默认角色
 *
 * @author zuihou
 * @date 2020年03月29日21:16:22
 */
@Component
@RefreshScope
@Data
public class ValueConstant implements Serializable {


    @Value("${desensitizer.enabled}")
    private Boolean desensitizerEnabled;

    @Value("#{'${desensitizer.idCarFiles:}'.empty ? null : '${desensitizer.idCarFiles:}'.split(' ')}")
    private List<String> idCarFiles;

    @Value("#{'${desensitizer.mobileFiles:}'.empty ? null : '${desensitizer.mobileFiles:}'.split(' ')}")
    private List<String> mobileFiles;

    @Value("#{'${desensitizer.emailFiles:}'.empty ? null : '${desensitizer.emailFiles:}'.split(' ')}")
    private List<String> emailFiles;

    @Value("#{'${desensitizer.nameFiles:}'.empty ? null : '${desensitizer.nameFiles:}'.split(' ')}")
    private List<String> nameFiles;

    @Value("#{'${desensitizer.excludeUrl:}'.empty ? null : '${desensitizer.excludeUrl:}'.split(' ')}")
    private List<String> excludeUrl;


    @Value("${com.eastfair.aeskey}")
    private String aeskey;

    @Value("${com.eastfair.sensitivity_publicKey}")
    private String sensitivityPublicKey;

    @Value("${com.eastfair.sensitivity_privateKey}")
    private String sensitivityPrivateKey;
}
